<?php

/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
namespace Usuario\Form;

//use Zend\Captcha\AdapterInterface as CaptchaAdapter;
//use Zend\Form\Element;  //importante
//use Zend\Form\Fieldset;
use Zend\Form\Form;     //importante
/*use Zend\InputFilter\Input;
use Zend\InputFilter\InputFilter;*/

class Formrol extends Form
{
    public function __construct($nombre = null) 
    {        
        parent::__construct($nombre);
        $this->add(array(
            'name' => 'codigo',
            'options' => array(
                //'label' => 'Valor Ahorros'
            ),
            'attributes' => array(
                'type'        => 'text',
                'class'       => 'form-control',
                'placeholder' => 'codigo'                
            )
        ));           
        $this->add(array(
            'name' => 'nombre',
            'options' => array(
                //'label' => 'Kilometraje'
            ),
            'attributes' => array(
                'type'        => 'text',
                'class'       => 'form-control',
                'placeholder' => 'nombre'                 
            )
        ));
       $this->add(array(
            'name' => 'grabar',
            'type'  => 'Submit',
           'options' => array(
                //'label' => 'Grabar'
            ),
            'attributes' => array(
                'value' => 'Salvar',
                'class' => 'btn btn-primary btn-lg'
            ),
        ));    
        //$this->printField();
    }
    public function printField()
    {
       $this->add(array(
            'name' => 'codigo',
            'options' => array(
                //'label' => 'Valor Ahorros'
            ),
            'attributes' => array(
                'type'        => 'text',
                'class'       => 'form-control',
                'placeholder' => 'codigo'                
            )
        ));           
        $this->add(array(
            'name' => 'nombre',
            'options' => array(
                //'label' => 'Kilometraje'
            ),
            'attributes' => array(
                'type'        => 'text',
                'class'       => 'form-control',
                'placeholder' => 'codigo'                 
            )
        ));
       $this->add(array(
            'name' => 'grabar',
            'type'  => 'Submit',
           'options' => array(
                //'label' => 'Grabar'
            ),
            'attributes' => array(
                'value' => 'Grabar Turno',
                'class' => 'btn btn-primary btn-lg'
            ),
        ));    
    }
    
}
